Skip to content

Conversation

@ilyvion
Copy link
Contributor

@ilyvion ilyvion commented Mar 29, 2025

It does this by checking whether it's exited or not, and if not, kills it. This ensures that the command doesn't keep running in the background or cause any other odd shell behaviors once cargo-leptos returns.

Presumably resolves #387

It does this by checking whether it's exited or not, and if not, kills
it. This ensures that the command doesn't keep running in the background
or cause any other odd shell behaviors once `cargo-leptos` returns.

Presumably resolves leptos-rs#387
@paul-hansen
Copy link
Contributor

It seems like this isn't killing the Leptos server that cargo-leptos end-to-end is starting so the ports are still staying in use.

I tested this locally on my Axum project by installing cargo-leptos using

cargo install cargo-leptos --git=https://github.com/ilyvion-contrib/cargo-leptos.git --branch=en2end-kill-cmd

@ilyvion
Copy link
Contributor Author

ilyvion commented Apr 27, 2025

I tested this locally on my Axum project by installing cargo-leptos using

cargo install cargo-leptos --git=https://github.com/ilyvion-contrib/cargo-leptos.git --branch=en2end-kill-cmd

Did you/could you try running it with RUSTLOG="trace" to see what the logging I added outputs?

@paul-hansen
Copy link
Contributor

Actually, I think the server only keeps running when the tests fail. If I make them all succeed it seems to kill it.

Note that cargo leptos doesn't seem to log it's logs based on RUST_LOG (I'd guess so you can use that for your app), you have to use cargo leptos end-to-end -vvv to enabling tracing logs. I still didn't see the new traces at all, though I'd guess the tests failing might be causing it to exit before it gets there?

@ilyvion
Copy link
Contributor Author

ilyvion commented Apr 28, 2025

I'd guess the tests failing might be causing it to exit before it gets there?

That's a thought. I can look into that next I'm able. 👍

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

end-to-end tests leave ports open if tests fail

2 participants